#!/bin/bash
#2018年6月6日21:02:25
#auto install lamp for yum
#by author www.jfedu.net
##########################
#Install Apache WEB
yum install -y httpd httpd-devel
#Install Mariadb Database 
yum install -y mariadb mariadb-devel mariadb-server 
#Install PHP WEB
yum install -y php php-mysql php-devel

#Config LAMP PHP pages for cat
cat>/var/www/html/info.php<<EOF
<?php
phpinfo();
?>
EOF

#Config LAMP PHP pages for echo
echo "
<?php
phpinfo();
?>
">/var/www/html/info.php

#Start Apache and Mariadb Service
setenforce 0
systemctl restart httpd.service
systemclt restart mariadb.service
systemclt stop firewalld.service
